<layout name="page" />
<block name="content">
	{:widget('page_header/simple',array('name'=>'添加供应商'))}
	<div class="frame">
		<form method='post' id="form_data" class="row">
			<input type="hidden" name="opmode" value="add">
			<input type="hidden" name="ajax" id="ajax" value="1">
			<div class="box col-6">
				<label class="input-label" for="name">公司名称*：</label>

				<input class="input" type="text" id="name" name="name" check="required" info="请输入名称">
			</div>
			<div class="box col-6">
				<label class="input-label" for="short">公司简称*：</label>
				<input class="input" type="text" id="short" name="short" check="required" info="请输入简称">
			</div>
			<div class="box col-6">
				<label class="input-label" for="account">帐号*：</label>
				<input class="input" type="text" id="account" name="account" check="required" info="请输入帐号">
			</div>
			<div class="box col-6">
				<label class="input-label" for="tax_no">税号*：</label>
				<input class="input" type="text" id="tax_no" name="tax_no" >
			</div>
			<div class="box col-6">
				<label class="input-label" for="payment">付款方式*：</label>
				<input class="input" type="text" id="payment" name="payment" >
			</div>
			<div class="box col-6">
				<label class="input-label" for="address">地址*：</label>
				<input class="input" type="text" id="address" name="address" >
			</div>
			<div class="box col-6">
				<label class="input-label" for="contact">联系人*：</label>
				<input class="input" type="text" id="contact" name="contact" check="required" info="请输入联系人">
			</div>
			<div class="box col-6">
				<label class="input-label" for="email">邮箱*：</label>
				<input class="input" type="text" id="email" name="email" check="required" info="请输入邮箱">
			</div>
			<div class="box col-6">
				<label class="input-label" for="email">办公电话*：</label>
				<input class="input" type="text" id="email" name="email" check="required" info="请输入办公电话">
			</div>
			<div class="box col-6">
				<label class="input-label" for="mobile_tel">手机*：</label>
				<input class="input" type="text" id="mobile_tel" name="mobile_tel" check="required" info="请输入手机">
			</div>
			<div class="box col-6">
				<label class="input-label" for="fax">传真：</label>
				<input class="input" type="text" id="fax" name="fax">
			</div>
			<div class="box col-6">
				<label class="input-label" for="im">即时聊天：</label>
				<input class="input" type="text" id="im" name="im" >
			</div>
			<div class="box col-12">
				<label class="input-label" for="remark" >其他：</label>
				<textarea class="textarea" name="remark" id="remark" rows="5"></textarea>
			</div>
			<div class="box col-12">
				<label class="input-label"></label>
				<a class="btn btn-normal" onclick="save()">保存</a>
				<a  class="btn btn-return" onclick="go_return_url();">取消</a>
			</div>
		</form>
	</div>
</block>
<block name="js">
	<script type="text/javascript">
		layui.use('global', function() {
			var fn = {
				save : function() {
					send_form("form_data", "{:url('save')}", "{:url('index')}", function(ret) {
						if (ret.status) {
							layer.msg(ret.info, {
								time : 1200
							}, function() {
								location.href = "{:url('index')}";
							});
						} else {
							layer.msg(ret.info);
							return false;
						}
					});
				}
			};
			win_exp(fn);
		});
	</script>
</block>